package com.homework.work03;

/**
 * 数组的循环赋值与取值
 */
public class ArrayDemo4 {
    public static void main(String[] args) {
        //定义数组
        int[] arr = new int[5];
        //循环赋值
        for (int i = 0; i < arr.length; i++) {
            arr[i] = i*5;
        }
        //循环取值
        for (int i = 0; i < arr.length ; i++) {
            System.out.println(arr[i]);
        }
    }
}
